/*-------------------------------------------------------------------------

***************** Modification History ***********************************
* @doc		COUNTER
* @module	counter.h
* Header file for counter functions.
*
* Product	: SoftPay 2000 (Global Payment Methodology).
* Developer	: Miami
* Notes		:
* Log		: /SoftPay/SPK2SIM/Source/Include/counter.h
**************************************************************************

   Copyright (C) 1999 by VeriFone, Inc.

   All rights reserved.  No part of this software may be reproduced,
   transmitted, transcribed, stored in a retrieval system, or translated
   into any language or computer language, in any form or by any means,
   electronic, mechanical, magnetic, optical, chemical, manual or otherwise,
   without the prior written permission of VeriFone, Inc.

---------------------------------------------------------------------------*/

#ifndef VSCOUNTER_H
#define VSCOUNTER_H

#include <cnt.h>
											/* Completed Transactions Counters */
											/* --------------------------------*/
#define TOTAL_TRANSACTIONS				0	/* Total			Transactions */
#define VOID_TRANSACTIONS				1	/* Void				Transactions */
#define ON_LINE_SALES					2	/* On  Line Sale	Transactions */
#define OFF_LINE_SALES	 				3	/* Off Line Sale	Transactions */
#define REFUND_TRANSACTIONS				4	/* Refund			Transactions */
#define PREAUTH_TRANSACTIONS			5	/* Auth Only		Transactions */
#define ADJUST_SALE_TRANSACTIONS		6	/* Adjust Sale  	Transactions */
#define ADJUST_REFUND_TRANSACTIONS		7	/* Adjust Refund	Transactions */
#define TIP_ADJUST_TRANSACTIONS			8	/* Tip Adjust   	Transactions */
#define REVERSAL_TRANSACTIONS			9	/* Auth Only		Transactions */
#define REFERRAL_TRANSACTIONS			10	/* Sale Completion	Transactions */
#define NON_APPROVED_TRANSACTIONS		11	/* Non-approved		Transactions */
#define DENIED_TRANSACTIONS				12	/* Denied			Transactions */

											/* General Counters */
											/* ---------------- */
#define ROCS_PRINTED					13 	/* "All" Printed Receipts Count	*/
#define MANUAL_ENTRIES					14	/* Manual Entries */
#define SWIPE_ENTRIES					15	/* Swipe  Entries */
#define TRANSACTIONS_PRIMARY			16	/* Primary   Line Transactions	*/
#define TRANSACTIONS_SECONDARY			17	/* Secondary Line Transactions	*/
#define RETRANSMITS						18	/* (= 0 in ISO)	  */
#define REDIAL_PRIMARY					19	/* Primary	 Line Redial	*/
#define REDIAL_SECONDARY				20	/* Secondary Line Redial	*/
#define CONNECT_TIME_OUT				21	/* E-CARRIER or NO-ANSWER	*/
#define TRANSACTION_TIME_OUT			22	/* Transaction response Timeout	*/
#define COMMUNICATION_ERROR				23	/* Transaction response Error	*/
#define BATCH_SET_RESP_TIME				24  /* Settlement time value	 */
#define RESPONSE_TIME					25	/* Total accum Resp time	 */
#define RESP_TIME_1						26	/* Resp time between  0 &  7 */
#define RESP_TIME_2						27	/* Resp time between  8 & 10 */
#define RESP_TIME_3						28	/* Resp time between 11 & 20 */
#define RESP_TIME_4						29	/* Resp time between 21 & 30 */
#define RESP_TIME_LI_1					30	/* Resp time between  0 & 18 since last input */
#define RESP_TIME_LI_2					31	/* Resp time between 19 & 30 since last input */
#define RESP_TIME_LI_3					32	/* Resp time between 31 & 45 since last input */
#define RESP_TIME_LI_4					33	/* Resp time > 45 since last input */
#define CARD_READ_ATTEMPTED				34  /* Of all the hosts */
#define CARD_READ_ERROR					35  /* Of all the hosts */

#define ALL_RECORDS		256

#define START_TIMER_1	0
#define  STOP_TIMER_1	1
#define START_TIMER_2	2
#define  STOP_TIMER_2	3
#define START_TIMER_3	4
#define  STOP_TIMER_3	5

typedef struct srCounterStruct
{
	int		inType ;
	int		inIndex;
	CNT_REC srCNT  ;
}
	COUNTER_OBJECT;

#endif	/* VSCOUNTER_H */
